
CFLAGS	+= -s -Os -D_GNU_SOURCE -W -Wall $(EXTRACFLAGS)
CFLAGS	+= -I. -I$(TOP)/shared -I$(SRCBASE)/include
#CFLAGS	+= -g -DDEBUG
CFLAGS	+= -fPIC

OBJS := atcommand.o common.o modem_cmd.o nvram.o usb_common.o usbmodem.o

all: librc.so

clean:
	rm -f *.o *.so modem

librc.so: $(OBJS)
	$(LD) -shared -o $@ $^

install: all
	install -D librc.so $(INSTALLDIR)/usr/lib/librc.so
	$(STRIP) $(INSTALLDIR)/usr/lib/librc.so
